'use strict';

/**
 * @ngdoc function
 * @name consoleAngularUiApp.service:serviceTypes
 * @description
 * # serviceTypesServ
 * Cloud Service Types service of the consoleAngularUiApp
 */
angular.module('consoleAngularUiApp')

    .factory('$serviceTypesServ', ['$resource', function ($resource){

        return $resource('/api/rest/rprm/servicetypes/:id', { }, {
            query: {
                isArray: true,
                headers: {
                    'Accept': 'application/vnd.plcm.plcm-service-type-list+json'
                }
            }
        });

    }])
    .factory('serviceTypesVal', ['$serviceTypesServ', function($serviceTypesServ){

        var servicetypes = $serviceTypesServ.query();

        return {
            $get: function(){
                return servicetypes;
            }
        }
    }])